<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8" %>
<%@ include file="/include.inc.jsp" %>
<style>

    .rights ul {
        margin: 0;
        padding: 10px 0;
    }

    .rights p {
        margin: 0;
        padding: 10px 0px 0px;
    }

    .rights ul li {
        width: 15%;
        float: left;
    )
</style>

<div class="panelBar">
    <ul class="toolBar">
        <li><a class="delete" href="/basesetting/goods!delete?goodsType.id=${goodsType.id}" target="ajaxTodo"
               title="确定要删除吗?<br>如果删除该目录类型，会删除旗下的商品。<br>慎用！！！！！"><span>删除</span></a></li>
        <li><a class="edit" href="/basesetting/goods!toAdd?goodsType.id=${goodsType.id}" target="dialog" title="用户组修改"
               rel="userNav"><span>修改</span></a></li>
        <li class="line">line</li>
    </ul>
</div>

<div class="panel" defH="600">
    <h1>[${goodsType.goodsName}]-旗下商品</h1>

    <div>


        <div class="pageContent">
            <div class="panelBar">
                <ul class="toolBar">
                    <li><a class="add" href="/basesetting/goods!toAddGoodsInfo?goodsType.id=${goodsType.id}" target="dialog"
                           title="商品添加" width="850" height="400"><span>添加</span></a></li>
                    <li><a class="delete" href="/basesetting/goods!delGoodsInfo?goodsInfo.id={sid_goodsInfo}" target="ajaxTodo"
                           title="确定要删除吗?"><span>删除</span></a></li>
                    <li><a class="edit" href="/basesetting/goods!toAddGoodsInfo?goodsInfo.id={sid_goodsInfo}" target="dialog" title="商品修改"
                           rel="userNav" width="850" height="400"><span>商品修改</span></a></li>
                    <li class="line">line</li>
                </ul>
            </div>
            <table class="table" width="100%" layoutH="138">
                <thead>
                <tr>
                    <th width="20"></th>
                    <th width="100">商品编号</th>
                    <th width="100">商品名称</th>
                    <th width="50">商品尺寸</th>
                    <th width="100">商品单位</th>
                    <th width="80">商品成本</th>
                    <th width="80">商品售价</th>
                    <th width="80">是否关联库存</th>
                    <th width="100">商品类别</th>
                </tr>
                </thead>
                <tbody>

                <c:forEach items="${goodsInfos}" var="user" varStatus="index">
                    <tr target="sid_goodsInfo" rel="${user.id}">
                        <td>${index.index+1}</td>
                        <td>${user.goodsNo}</td>
                        <td>${user.goodsName}</td>
                        <td>${user.goodsSize}</td>
                        <td>${user.goodsUnit}</td>
                        <td>${user.goodsBuyPrice}</td>
                        <td>${user.goodsSellPrice}</td>
                        <td>
                            <c:choose>
                                <c:when test="${user.inventoryStatus==0}">
                                    关联
                                </c:when>
                                <c:otherwise>
                                    不关联
                                </c:otherwise>
                            </c:choose>
                        </td>
                        <td>     <%--消耗品  必需品  内部使用--%>
                            <c:choose>
                                <c:when test="${user.goodsStatus==1}">
                                    消耗品
                                </c:when>
                                <c:when test="${user.goodsStatus==2}">
                                    必需品
                                </c:when>
                                <c:otherwise>
                                    内部使用
                                </c:otherwise>
                            </c:choose>
                        </td>
                    </tr>
                </c:forEach>
                </tbody>
            </table>
            <div class="panelBar">
                <div class="pages">
                    <span>显示</span>
                    <select class="combox" name="numPerPage" onchange="navTabPageBreak({numPerPage:this.value})">
                        <option value="20">20</option>
                        <option value="50">50</option>
                        <option value="100">100</option>
                        <option value="200">200</option>
                    </select>
                    <span>条，共${totalCount}条</span>
                </div>

                <div class="pagination" targetType="navTab" totalCount="200" numPerPage="20" pageNumShown="10"
                     currentPage="1"></div>

            </div>
        </div>
    </div>
</div>
